<%@ page import="com.msti.entity.Student"%>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title >Student Registration</title>
<link rel="stylesheet" type="text/css" href="css/common.css" />
<script type="text/javascript" src="js/common.js"></script>
</head>
<body>
<%
	Student student = (Student)request.getAttribute("student");
	String title = "";
	String buttonValue = "";
	String DOBString ="";
	if(student == null){
		response.sendRedirect("index.jsp");
		//student.setDateOfBirth(02/01/2012);
	}
	
%>
<div class="wrapper">
	<form action="updateStudent.do" method="post" id="reg_form" onSubmit="return regRequired();">
		<div id="form_header">Update Student</div>
		<ul>
			<li>
				<p class="label">Full Name :</p>
				<input type="text" name="fullName" class="txt_field" value="<%=student.getFullName() %>"/>
			</li>
			<li>
				<p class="label">NIC :</p>
				<input type="text" name="NICNO" class="txt_field" id="nic" value="<%=student.getNICNO() %>"/>
			</li>
			<li>
				<p class="label">Address :</p>
				<input type="text" name="address" class="txt_field" value="<%=student.getAddress() %>" />
			</li>
			<li>
				<p class="label">Passport No :</p>
				<input type="text" name="passportNo" class="txt_field" id="passport" value="<%=student.getPassportNo() %>"/>
			</li>
			<li>
				<p class="label">CDC :</p>
				<input type="text" name="CDCNO" class="txt_field" id="cdc" value="<%=student.getCDCNO() %>"/>
			</li>
			<li>
				<p class="label">Phone :</p>
				<input type="text" name="phone" class="txt_field" value="<%=student.getPhone()%>"/>
			</li>
			<li>
				<p class="label">Date Of Birth :</p>
				<input type="text" name="dateOfBirth" class="txt_field" value="<%=student.getDateOfBirth()%>"/>
			</li>
			<input type="hidden"  name="id" value="<%=student.getStudentID() %>" />
			
			<li>
				<p class="label">&nbsp;</p>
				<input type="submit" value="Update" class="submit_btn">
			</li>
		</ul>
	</form>
	
	<div class="company_name_bar"><marquee direction="left">Mercantile Seamen Training Institute Ltd.</marquee></div>
</div>
</body>
</html>
